#ifndef _SENSOR_H_
#define _SENSOR_H_

#define MSG_SENSOR_LAST   0
#define MSG_SENSOR_QUERY  1
#define MSG_SENSOR_DATA   2

typedef struct __sensor_req {
  int type;
  char name[5];
  char data[10];
} sensor_req;

typedef struct __sensor_reply {
  int result;
  char name[5];
} sensor_reply;

/**
 * The SensorManager is responsible for polling sensors (via SensorNotifier)
 * and keeping track of triggered sensors. It responds to requests for either
 * the last triggered sensor or the state of a given sensor.
 */
void SensorManager();

/* Returns the external ID of the last sensor triggered. */
//void LastSensor(char *name);

/* Returns TRUE iff the sensor with the given external ID was triggered in
   the last poll. */
//int QuerySensor(char *name);

#endif
